home *** CD-ROM | disk | FTP | other *** search
/ Star Trek Starfleet Academy Mini Omnipedia / MINI_OMNI.ISO / pc / omni_v2.dxr / 00397_Interface button Calls.ls < prev    next >
Encoding:
Text File  |  1996-04-15  |  16.1 KB  |  573 lines

  1. global oINTERfaceENTRYpush, oINTERfaceENCpush, oIndexScroller, gExtraSpeed, oINTERfaceEpis, oINTERfaceModes, oINTERfaceFind, oINTERfaceNext, oINTERfaceAlph, gDefaultENTRYstate, gDefaultENCstate, gDefaultSearchstate, gDefaultTextstate, gDefaultPixelstate, gSearchPopOut, gCloseHlt, gFlashPixel, gUpdateBase, vENCpushBaseCast, vENTRYpushBaseCast, gPullDownModes, gPullDownSearch, gFindBase, gAlphBase, gColorMac, gEpisBase, gModeBase, gComputerTypeK, gModeList, gHoldEntPixelSprite, gHoldEncPixelSprite, oINTERfaceUpdate, gCastVideoHlt, gCastAudioHlt, gCastResHlt, gBlankBar, gPixelHold, gHoldENCstate, gNextBase, gDefaultWordBar, gHoldSearchInfo, gTbarSND, gWhereIam, gResumeHlt, gQuitHlt, gTopicBase, oINTERfaceTopicControl, gTopIsPaused, oCHROPopup1, oCHROPopup2, gFTstartSND, gPrepareSND, gSpeechWasChosenF, gTheFTword, gModeState, gActiveResTopWin, gFTsearchscope, gSavedMouseUpScript, gthisisahack, gtheblackbar, oVidCD, gSearchState, gSavedMouseUpScriptforQuit, gModeList2, gOptionBaseCastMem, oINTERfaceOptions, gHltPixel, oINTERfaceAddArtical, oImportDeleteImport, oImportAddSameName, oImportOKorCancel, oImportSkipAppend, oImportDeleteORresume
  2.  
  3. on hInterFace
  4.   set gHoldSearchInfo to 0
  5.   set gColorMac to the colorDepth
  6.   hSetSpeed()
  7.   set vFindBaseCastMem to the number of cast "FindBASE"
  8.   set vNextBaseCastMem to the number of cast "NextBASE"
  9.   set vAlphBaseCastMem to the number of cast "AlphBASE"
  10.   set vEpisBaseCastMem to the number of cast "EpisBASE"
  11.   set vModeBaseCastMem to the number of cast "ModeBASE"
  12.   set gOptionBaseCastMem to the number of cast "Options Pop Out"
  13.   set vTopicControlBaseCast to the number of cast "TopicControlBase"
  14.   set gResumeHlt to the number of cast "resumeHlt"
  15.   set gQuitHlt to the number of cast "quitHlt"
  16.   set gDefaultENTRYstate to the number of cast "entryBASE"
  17.   set gHoldENCstate to the number of cast "BlankBar"
  18.   set gthisisahack to gDefaultENTRYstate
  19.   set gDefaultWordBar to the number of cast "wordBASE"
  20.   set gDefaultENCstate to the number of cast "BlankBar"
  21.   set gtheblackbar to gDefaultENCstate
  22.   set gDefaultSearchstate to the number of cast "searchBASE"
  23.   set gDefaultTextstate to the number of cast "searchtextcandidate"
  24.   set gDefaultPixelstate to the number of cast "PixelREF"
  25.   set gCloseHlt to the number of cast "CloseHlt"
  26.   set vENTRYpushBaseCast to the number of cast "ENTRYpulldownBASE"
  27.   set gModeList to [#ENCY, #EPIS, #CHRO, #Resources, #TOPICS, #FoundSet, #EPISSUB]
  28.   set gModeList2 to [#ENCY, #EPIS, #CHRO, #ALL]
  29.   set gCastVideoHlt to the number of cast "video 1"
  30.   set gCastAudioHlt to the number of cast "audio 1"
  31.   set gCastResHlt to the number of cast "resource 1"
  32.   set gBlankBar to the number of cast "BlankBar"
  33.   set gPixelHold to the number of cast "PixelREF"
  34.   set vUpdateBaseCastMem to the number of cast "FoundsetBase"
  35.   set oINTERfaceUpdate to birth(script "Interface Hlt Script2", gUpdateBase, 2, vUpdateBaseCastMem, 156)
  36.   if not objectp(oINTERfaceUpdate) then
  37.     beep(4)
  38.   end if
  39.   set oINTERfaceFind to birth(script "Interface Hlt Script", gFindBase, 3, vFindBaseCastMem)
  40.   if not objectp(oINTERfaceFind) then
  41.     beep(4)
  42.   end if
  43.   set oINTERfaceNext to birth(script "Interface Hlt Script", gNextBase, 3, vNextBaseCastMem)
  44.   if not objectp(oINTERfaceNext) then
  45.     beep(4)
  46.   end if
  47.   set oINTERfaceAlph to birth(script "Interface Hlt Script2", gAlphBase, 26, vAlphBaseCastMem, 12)
  48.   if not objectp(oINTERfaceAlph) then
  49.     beep(4)
  50.   end if
  51.   set oINTERfaceEpis to birth(script "Interface Hlt Script2", gEpisBase, 6, vEpisBaseCastMem, 52)
  52.   if not objectp(oINTERfaceEpis) then
  53.     beep(4)
  54.   end if
  55.   set oINTERfaceOptions to birth(script "Interface Hlt Script", gPullDownModes, 2, gOptionBaseCastMem)
  56.   if not objectp(oINTERfaceAlph) then
  57.     beep(4)
  58.   end if
  59.   set oINTERfaceENTRYpush to birth(script "Interface Hlt Script", gPullDownSearch, 2, vENTRYpushBaseCast)
  60.   if not objectp(oINTERfaceENTRYpush) then
  61.     beep(4)
  62.   end if
  63.   set oINTERfaceTopicControl to birth(script "Interface Hlt Script", gTopicBase, 4, vTopicControlBaseCast)
  64.   if not objectp(oINTERfaceTopicControl) then
  65.     beep(4)
  66.   end if
  67. end
  68.  
  69. on hCallbirthforButtonsHere
  70.   set oINTERfaceAddArtical to birth(script "Interface Hlt Script", 9, 3, the number of cast "ImportArtButtons")
  71.   set oImportDeleteImport to birth(script "Interface Hlt Script", 14, 2, the number of cast "DeleteImportArtic")
  72.   set oImportAddSameName to birth(script "Interface Hlt Script", 15, 3, the number of cast "ImportAddSameName")
  73.   hReportStatus("Preparing interface parameters...")
  74.   set oImportOKorCancel to birth(script "Interface Hlt Script", 16, 2, the number of cast "OK Cancel")
  75.   set oImportSkipAppend to birth(script "Interface Hlt Script", 17, 2, the number of cast "SKIP&APPEND")
  76.   set oImportDeleteORresume to birth(script "Interface Hlt Script", 19, 2, the number of cast "DeleteImportArtic")
  77.   hReportStatus("Ready...")
  78. end
  79.  
  80. on hcallfaceAddSameName
  81.   global mouseUp, oImport
  82.   set vResult to mHltVer(oImportAddSameName)
  83.   if vResult = 1 then
  84.     mSkipNewEntry(oImport)
  85.   else
  86.     if vResult = 2 then
  87.       mReplaceSameName(oImport)
  88.     else
  89.       if vResult = 3 then
  90.         mReNameNewTopic(oImport)
  91.       end if
  92.     end if
  93.   end if
  94. end
  95.  
  96. on hCallImportDeleteOkCancel
  97.   global oImport, gDeleteLine
  98.   set vResult to mHltVer(oImportOKorCancel)
  99.   if vResult = 1 then
  100.     mDeleteSingleEntry(oImport, gDeleteLine)
  101.     set gDeleteLine to 0
  102.     go("TopicDelete")
  103.   else
  104.     set gDeleteLine to 0
  105.     go("TopicDelete")
  106.   end if
  107. end
  108.  
  109. on hCallImportOkCancel
  110.   global oImport, gTopicNameField
  111.   set vResult to mHltVer(oImportOKorCancel)
  112.   if vResult = 1 then
  113.     if the text of field gTopicNameField <> EMPTY then
  114.       mEnterNewName(oImport)
  115.     end if
  116.   else
  117.     if vResult = 2 then
  118.       mCancelNewName(oImport)
  119.     else
  120.     end if
  121.   end if
  122. end
  123.  
  124. on hcalImportSkipAppend
  125.   global oImport
  126.   set vResult to mHltVer(oImportSkipAppend)
  127.   if vResult = 1 then
  128.     mSkipNewEntry(oImport)
  129.   else
  130.     if vResult = 2 then
  131.       mReNameNewTopic(oImport)
  132.     end if
  133.   end if
  134. end
  135.  
  136. on hCallDeleteArticalButs
  137.   global oImport
  138.   set vResult to mHltVer(oImportDeleteORresume)
  139.   if vResult = 1 then
  140.     mStartUserDelete(oImport)
  141.   else
  142.     if vResult = 2 then
  143.       hLeaveTopicEdit()
  144.     end if
  145.   end if
  146. end
  147.  
  148. on hCallAddArticleButs
  149.   global gAddField, oImport
  150.   set vResult to mHltVer(oINTERfaceAddArtical)
  151.   if vResult = 1 then
  152.     mStartUserImport(oImport)
  153.   else
  154.     if vResult = 2 then
  155.       set the textStyle of field gAddField to "bold"
  156.     else
  157.       if vResult = 3 then
  158.         hLeaveTopicEdit()
  159.       end if
  160.     end if
  161.   end if
  162. end
  163.  
  164. on hSetSpeed
  165.   if gComputerTypeK = #mac then
  166.     if gColorMac = 32 then
  167.       set gExtraSpeed to 137
  168.     else
  169.       if gColorMac = 16 then
  170.         set gExtraSpeed to 127
  171.       else
  172.         set gExtraSpeed to 97
  173.       end if
  174.     end if
  175.   else
  176.     set gExtraSpeed to 97
  177.   end if
  178. end
  179.  
  180. on hcallupdate
  181.   set vResult to mHltHor(oINTERfaceUpdate, gHltPixel)
  182.   hputmsg(">hCallUpdate> returns>" && vResult)
  183.   if vResult = 1 then
  184.     hShowTheUpdate(3)
  185.   else
  186.     if vResult = 2 then
  187.       hearit(gFTstartSND)
  188.       if not (gTheFTword starts "[") then
  189.         hShowTheFoundHits(1, 1)
  190.       else
  191.         hShowTheFoundHits(1, 0)
  192.       end if
  193.     end if
  194.   end if
  195. end
  196.  
  197. on hCallFind
  198.   set vResult to mHltVerWithOption(oINTERfaceFind, 1)
  199.   if vResult = 1 then
  200.     mPopSearchStrip(oINTERfaceFind)
  201.   else
  202.     if vResult = 2 then
  203.       hGoHelp()
  204.     else
  205.       if vResult = 39 then
  206.         if gModeState <> #TOPICS then
  207.           hSwitchSpeech()
  208.         else
  209.           hReportStatus("Speech not available in Topics mode.")
  210.         end if
  211.       else
  212.         if vResult = 49 then
  213.           hPopOptions()
  214.         else
  215.           if vResult = 3 then
  216.             hBolt()
  217.           end if
  218.         end if
  219.       end if
  220.     end if
  221.   end if
  222. end
  223.  
  224. on hPopOptions
  225.   mSwitchHold(oINTERfaceOptions, 179, 92, gOptionBaseCastMem, gPullDownModes)
  226.   repeat while the stillDown
  227.     mSwitchHold(oINTERfaceOptions, 179, 92, gOptionBaseCastMem, gPullDownModes)
  228.     if rollOver(gPullDownModes) then
  229.       set vResult to mRollOverHorizontal(oINTERfaceOptions)
  230.       if not voidp(vResult) then
  231.         set vHoldResult to vResult
  232.       end if
  233.       next repeat
  234.     end if
  235.     set the castNum of sprite gFlashPixel to gPixelHold
  236.     updateStage()
  237.     set vHoldResult to EMPTY
  238.   end repeat
  239.   puppetSprite(gPullDownModes, 0)
  240.   if vHoldResult = 1 then
  241.     hGoTopicEdit()
  242.   else
  243.     if vHoldResult = 2 then
  244.       hPrintEntry()
  245.     end if
  246.   end if
  247. end
  248.  
  249. on hBolt
  250.   set gWhereIam to the frame
  251.   hHelpWinClose()
  252.   hStoreLockWins()
  253.   hStorePuppets()
  254.   hStoreVisibles()
  255.   if gModeState = #TOPICS then
  256.     if string(the windowList) contains gActiveResTopWin then
  257.       hCloseTopWin()
  258.       forget(window gActiveResTopWin)
  259.     end if
  260.     set the visible of sprite gTopicBase to 0
  261.     mClearTopHlt(oINTERfaceTopicControl)
  262.   end if
  263.   if gModeState = #Resources then
  264.     hResetResMode()
  265.     set gSavedMouseUpScript to the mouseUpScript
  266.     set the mouseUpScript to EMPTY
  267.   end if
  268.   go("Later")
  269.   hAnnounce("Please Confirm Alpha deact.")
  270.   if gComputerTypeK = #WIN then
  271.     hWinVoiceStartQuit()
  272.   end if
  273.   set gSavedMouseUpScriptforQuit to the keyDownScript
  274.   set the keyDownScript to EMPTY
  275. end
  276.  
  277. on hCallNext
  278.   set vResult to mHltVer(oINTERfaceNext)
  279.   if gModeState = #CHRO then
  280.     hResetMediaButts()
  281.   end if
  282.   if vResult = 1 then
  283.     hStepNext()
  284.   end if
  285.   if vResult = 2 then
  286.     hStepPrev()
  287.   end if
  288.   if vResult = 3 then
  289.     hBackTrack()
  290.   end if
  291. end
  292.  
  293. on hCallTopicControl
  294.   set x to the mouseV
  295.   set y to the mouseH
  296.   set vResult to mHltTopVer(oINTERfaceTopicControl, 1)
  297.   if vResult = 1 then
  298.     hResumeTopWin()
  299.   end if
  300.   if vResult = 3 then
  301.     hRewindTopWin()
  302.     if gTopIsPaused then
  303.       mForceTopHlt(oINTERfaceTopicControl, 4)
  304.     else
  305.       mForceTopHlt(oINTERfaceTopicControl, 1)
  306.     end if
  307.   end if
  308.   if vResult = 4 then
  309.     hPauseTopWin()
  310.   end if
  311. end
  312.  
  313. on hCallHltModes pWhat
  314.   hputmsg("hCallHltModes to" && pWhat)
  315.   if not (the puppet of sprite 40) then
  316.     puppetSprite(40, 1)
  317.   end if
  318.   if not (the puppet of sprite 18) then
  319.     puppetSprite(18, 1)
  320.   end if
  321.   if pWhat = #ENCY then
  322.     set the castNum of sprite 40 to the number of cast "encyclopedia hilite"
  323.     set the castNum of sprite 18 to the number of cast "foundentries base"
  324.     updateStage()
  325.   else
  326.     if pWhat = #FoundSet then
  327.       set the castNum of sprite 40 to the number of cast "encyclopedia base"
  328.       set the castNum of sprite 18 to the number of cast "foundentries hilite"
  329.       updateStage()
  330.     else
  331.       put "***!*** hCallHltModes cant work with" && pWhat
  332.     end if
  333.   end if
  334. end
  335.  
  336. on hCallResume
  337.   if the soundBusy of 1 then
  338.     puppetSound(0)
  339.   end if
  340.   if gComputerTypeK = #WIN then
  341.     hWinVoiceEndQuit()
  342.   end if
  343.   hSwitchCast(8, gResumeHlt, 8)
  344.   if (gModeState <> #TOPICS) and (gModeState <> #Resources) then
  345.     hAnnounce("Reastablishing Link")
  346.   end if
  347.   go(gWhereIam)
  348.   hRestorePuppets()
  349.   hRestoreVisibles()
  350.   if (gModeState = #TOPICS) or (gModeState = #Resources) then
  351.     hPlaceEntryRequest(0)
  352.     set the mouseUpScript to gSavedMouseUpScript
  353.     set gSavedMouseUpScript to EMPTY
  354.   end if
  355.   if gModeState <> #TOPICS then
  356.     hRestoreLockWins()
  357.   end if
  358.   set the keyDownScript to gSavedMouseUpScriptforQuit
  359. end
  360.  
  361. on hCallQuit
  362.   hSwitchCast(9, gQuitHlt, 9)
  363.   puppetSound("Deactivation Complete")
  364.   go(label("SS Animation"))
  365. end
  366.  
  367. on hCallHltHoriz pWhat
  368.   mHltfromScriptsVer(oINTERfaceFind, pWhat)
  369. end
  370.  
  371. on hCallHltNEXT pWhat
  372.   mHltfromScriptsVer2(oINTERfaceNext, pWhat)
  373. end
  374.  
  375. on hCallAlph
  376.   hearit(gTbarSND)
  377.   set vResult to mHltHor(oINTERfaceAlph, gHltPixel)
  378.   mShiftWindowToItem(oIndexScroller, vResult)
  379. end
  380.  
  381. on hKeyCallAlph
  382.   hearit(gTbarSND)
  383.   set vResult to mHltKeyHor(oINTERfaceAlph)
  384.   mShiftWindowToItem(oIndexScroller, vResult)
  385. end
  386.  
  387. on hCallEpis
  388.   hearit(gTbarSND)
  389.   set vResult to mHltHor(oINTERfaceEpis, gHltPixel)
  390.   mSwitchtoEpisSubindex(oIndexScroller, vResult)
  391. end
  392.  
  393. on hCallClear
  394.   mLeaveMode(oCHROPopup1)
  395.   mLeaveMode(oCHROPopup2)
  396.   mLeaveMode(oINTERfaceAlph)
  397.   mLeaveMode(oINTERfaceEpis)
  398.   mLeaveMode(oINTERfaceUpdate)
  399. end
  400.  
  401. on hCallClearPuppsAlph
  402.   mLeaveMode(oINTERfaceAlph)
  403. end
  404.  
  405. on hCallClearPuppsEpis
  406.   mLeaveMode(oINTERfaceEpis)
  407. end
  408.  
  409. on hCallClearPuppsUpdate
  410.   mLeaveMode(oINTERfaceUpdate)
  411. end
  412.  
  413. on hCallClosePopup
  414.   set vWhereClick to getAt(the clickLoc, 1)
  415.   if vWhereClick < 86 then
  416.     hSwitchCast(gFlashPixel, gCloseHlt)
  417.     set the castNum of sprite gFlashPixel to gPixelHold
  418.     mPopSearchStrip(oINTERfaceFind)
  419.   end if
  420. end
  421.  
  422. on hCallSearch
  423.   hSwitchCast(gFlashPixel, gDefaultSearchstate + 1)
  424.   hSearchRequest()
  425. end
  426.  
  427. on hCallResource pMySpr
  428.   hSwitchCast(gFlashPixel, gCastResHlt, pMySpr)
  429.   hShowResource()
  430. end
  431.  
  432. on hCallAudio pMySpr
  433.   hSwitchCast(gFlashPixel, gCastAudioHlt, pMySpr)
  434.   hOpenAudio()
  435. end
  436.  
  437. on hCallvideo pMySpr
  438.   hSwitchCast(gFlashPixel, gCastVideoHlt, pMySpr)
  439.   mSetCDNum(oVidCD, getAt(gcurrentmedialist, 3))
  440.   if mVidCDisMounted(oVidCD) then
  441.     hOpenVideo()
  442.   else
  443.     mRequestCDSwap(oVidCD, #video)
  444.   end if
  445. end
  446.  
  447. on hCallEntry
  448.   mPushDown(oINTERfaceENTRYpush, 464, 81, 13 + gExtraSpeed)
  449.   mSwitchHold(oINTERfaceENTRYpush, 464, 26, gDefaultENTRYstate, gHoldEntPixelSprite)
  450.   if gDefaultENTRYstate = (vENTRYpushBaseCast + 3) then
  451.     set gDefaultENCstate to gBlankBar
  452.   else
  453.     if gDefaultENTRYstate = (vENTRYpushBaseCast + 4) then
  454.       set gDefaultENCstate to gHoldENCstate
  455.     end if
  456.   end if
  457.   hputmsg(">hcallentry complete.")
  458. end
  459.  
  460. on hUserSelectWord
  461.   if gHoldSearchInfo = 1 then
  462.     mSwitchHold(oINTERfaceENTRYpush, 464, 26, gDefaultWordBar, gHoldEntPixelSprite)
  463.   else
  464.     set gDefaultWordBar to gDefaultWordBar
  465.     set gHoldENCstate to gHoldENCstate
  466.   end if
  467. end
  468.  
  469. on hUserGrabWord
  470.   if gHoldSearchInfo = 1 then
  471.     mSwitchHold(oINTERfaceENTRYpush, 464, 26, gDefaultWordBar, gHoldEntPixelSprite)
  472.     if gModeState = #FoundSet then
  473.       set vThisBar to getPos(gModeList2, gFTsearchscope)
  474.     else
  475.       set vThisBar to getPos(gModeList2, gModeState)
  476.     end if
  477.     if (vThisBar < 1) or (vThisBar > 4) then
  478.       set vThisBar to 1
  479.     end if
  480.     set gHoldENCstate to vENCpushBaseCast + 4 + vThisBar
  481.     hputmsg(">husergrabword just set gholdencstate to" && gHoldENCstate)
  482.   else
  483.     set gDefaultWordBar to gDefaultWordBar
  484.     set gHoldENCstate to gHoldENCstate
  485.   end if
  486. end
  487.  
  488. on hUserSelectEntry
  489.   if gHoldSearchInfo = 1 then
  490.     set gSearchState to #ENTRY
  491.     set gDefaultENTRYstate to gthisisahack
  492.     mSwitchHold(oINTERfaceENTRYpush, 464, 26, gDefaultENTRYstate, gHoldEntPixelSprite)
  493.     set gDefaultENCstate to gBlankBar
  494.   else
  495.     set gDefaultENTRYstate to gDefaultENTRYstate
  496.     set gDefaultENCstate to gBlankBar
  497.     set gDefaultENCstate to gDefaultENCstate
  498.   end if
  499. end
  500.  
  501. on hSwitchCast whichsprite, vwhom, pMySpr
  502.   if voidp(pMySpr) then
  503.     set vClick to the clickOn
  504.   else
  505.     set vClick to pMySpr
  506.   end if
  507.   puppetSprite(whichsprite, 1)
  508.   set the locV of sprite whichsprite to the top of sprite vClick
  509.   set the locH of sprite whichsprite to the left of sprite vClick
  510.   set the castNum of sprite whichsprite to vwhom
  511.   updateStage()
  512.   repeat while the stillDown
  513.     nothing()
  514.   end repeat
  515.   puppetSprite(whichsprite, 0)
  516.   updateStage()
  517. end
  518.  
  519. on hmoderoll psprnum
  520.   puppetSprite(psprnum, 1)
  521.   set Lme to the castNum of sprite psprnum
  522.   repeat while the stillDown
  523.     set the castNum of sprite psprnum to the castNum of sprite psprnum + rollOver(psprnum)
  524.     updateStage()
  525.     set the castNum of sprite psprnum to Lme
  526.   end repeat
  527.   if rollOver(psprnum) = 0 then
  528.     return 
  529.   end if
  530.   updateStage()
  531.   puppetSprite(psprnum, 0)
  532.   hputmsg("hmoderoll decides whether to call hcallmodes")
  533.   if psprnum = 40 then
  534.     hCallModes(1)
  535.   else
  536.     if psprnum = 18 then
  537.       hCallModes(6)
  538.     end if
  539.   end if
  540. end
  541.  
  542. on hHelpmoderoll psprnum
  543.   if psprnum = 40 then
  544.     if not (the puppet of sprite 40) then
  545.       puppetSprite(40, 1)
  546.     end if
  547.     set the castNum of sprite 18 to the number of cast "foundentries base"
  548.   else
  549.     if not (the puppet of sprite 18) then
  550.       puppetSprite(18, 1)
  551.     end if
  552.     set the castNum of sprite 40 to the number of cast "encyclopedia base"
  553.   end if
  554.   set the castNum of sprite psprnum to the castNum of sprite psprnum + 1
  555.   updateStage()
  556. end
  557.  
  558. on hCallModes pResult
  559.   if voidp(pResult) then
  560.     set pResult to mHltModes(oINTERfaceModes)
  561.   end if
  562.   hputmsg(">hCallModes> returns>" && pResult)
  563.   if pResult = 1 then
  564.     hSetMode(#ENCY)
  565.     hRecall(gModeState)
  566.   else
  567.     if pResult = 6 then
  568.       hSetMode(#FoundSet)
  569.       hRecall(gModeState)
  570.     end if
  571.   end if
  572. end
  573.